package com.dux.commons.database;

import java.io.File;

import com.dux.commons.configuration.Property;



/**
 * 数据库配置
 * 
 * @author 杜祥
 * @create 2013-5-20
 */
public class DatabaseConfig
{

	/**
	 * URL
	 */
	@Property(key = "database.url", defaultValue = "jdbc:mysql://localhost:3306/game")
	public static String		DATABASE_URL;

	/**
	 * Driver
	 */
	@Property(key = "database.driver", defaultValue = "com.mysql.jdbc.Driver")
	public static Class<?>		DATABASE_DRIVER;

	/**
	 * 用户名
	 */
	@Property(key = "database.user", defaultValue = "root")
	public static String		DATABASE_USER;

	/**
	 * 密码
	 */
	@Property(key = "database.password", defaultValue = "root")
	public static String		DATABASE_PASSWORD;

	/**
	 * 最小始终处于活跃状态的连接
	 */
	@Property(key = "database.connections.min", defaultValue = "2")
	public static int			DATABASE_CONNECTIONS_MIN;

	/**
	 * 连接的最大数量
	 */
	@Property(key = "database.connections.max", defaultValue = "10")
	public static int			DATABASE_CONNECTIONS_MAX;

	/**
	 * 数据库脚本描述文件的位置
	 */
	@Property(key = "database.scriptcontext.descriptor", defaultValue = "./data/scripts/system/database/database.xml")
	public static File			DATABASE_SCRIPTCONTEXT_DESCRIPTOR;
}
